<script>
	export default {
		onLaunch: function() {
			console.log('App Launch')
			    uni.getSystemInfo({
			        success: (rel) => {
			          // 获取是px值
			          // 状态栏的高度
					  console.log(rel);
			          console.log(rel.statusBarHeight);
			          // 视口的宽度
			          // console.log(rel.windowWidth);
			
			          // 转化为rpx然后获取
			          // rel.statusBarHeight*(750/rel.windowWidth)
			          this.globalData.navBarHeight = rel.statusBarHeight * (750 / rel.windowWidth) + 88;
			          // this.globalData.screenHeight = rel.screenHeight* (750 / rel.windowWidth);
			
			        }
			      }
			    )
		},
		onShow: function() {
			console.log('App Show')
		},
		onHide: function() {
			console.log('App Hide')
		},
	  // 全局变量
	  globalData: {
	    userInfo: null,
	    navBarHeight: null,
	  }
	}
</script>

<style lang="scss">
	/*每个页面公共css */
	// 3.引入基础样式
	@import "@/uni_modules/uview-ui/index.scss";
	@import '@/static/assets/css/iconfont.css';
</style>
